# -*- coding: utf-8 -*-
#
# @Time    ： 2023/10/26  0:41
# @Auther  ： 徐良
# File     :  mesLabels.py

from PySide6.QtWidgets import QLabel


class LabelBase(QLabel):

    def __init__(self, parent=None, iLen=None):
        super(LabelBase, self).__init__(parent)

        self.ROB = 0

    def setROB(self, value):
        if self.ROB != value:
            self.ROB = value
            self.setStyleSheet("color: red;") if self.ROB == 1 else self.setStyleSheet("color: rgb(37, 43, 65);")

class LabelBill(LabelBase):

    def __init__(self, parent=None):
        self.ROB = 0
        super(LabelBill, self).__init__(parent)



css1 = """
   QLabel {
       font: 75 20pt "微软雅黑";
       color: rgb(37, 43, 65);
       border: none;
   };
   """

css2 = """
   QLabel {
        font: 75 14pt "微软雅黑";
        color: rgb(37, 43, 65);
        border: none;
   };
   """

css3 = """
   QLabel {
        font: 75 10pt "微软雅黑";
        color: rgb(37, 43, 65);
        border: none;
   };
   """

css11 = """
   QLabel {
       font: 75 20pt "微软雅黑";
       color: rgb(37, 43, 65);
       border: 0px solid blue;
       margin: 0px; padding: 0px;
   };
   """

css12 = """
   QLabel {
        font: 75 14pt "微软雅黑";
        color: rgb(37, 43, 65);
        border: 0px solid blue;
        margin: 0px; padding: 0px;
   };
   """

css13 = """
   QLabel {
        font: 75 10pt "微软雅黑";
        color: rgb(37, 43, 65);
        border: 0px solid blue;
        margin: 0px; padding: 0px;
   };
   """

class Label1(LabelBase):

    def __init__(self, parent=None):
        super(Label1, self).__init__(parent)
        self.setStyleSheet(css1)


class Label2(LabelBase):

    def __init__(self, parent=None):
        super(Label2, self).__init__(parent)
        self.setStyleSheet(css2)


class Label3(LabelBase):

    def __init__(self, parent=None):
        super(Label3, self).__init__(parent)
        self.setStyleSheet(css3)


